package com.codejoys.monitor.dto;

import java.util.ArrayList;
import java.util.List;

public class SystemStatus {
    // modbus status
    // can status

    private List<CabinetStatus> cabinetStatusList = new ArrayList<>();
    private List<CanStatus> canStatusList = new ArrayList<>();

    public List<CabinetStatus> getCabinetStatusList() {
        return cabinetStatusList;
    }

    public void setCabinetStatusList(List<CabinetStatus> cabinetStatusList) {
        this.cabinetStatusList = cabinetStatusList;
    }

    public List<CanStatus> getCanStatusList() {
        return canStatusList;
    }

    public void setCanStatusList(List<CanStatus> canStatusList) {
        this.canStatusList = canStatusList;
    }


    public static class CabinetStatus {
        private String cabinet;
        private boolean isConnected;
        private boolean isReadWriteNormal;

        public String getCabinet() {
            return cabinet;
        }

        public void setCabinet(String cabinet) {
            this.cabinet = cabinet;
        }

        public boolean isConnected() {
            return isConnected;
        }

        public void setConnected(boolean connected) {
            isConnected = connected;
        }

        public boolean isReadWriteNormal() {
            return isReadWriteNormal;
        }

        public void setReadWriteNormal(boolean readWriteNormal) {
            isReadWriteNormal = readWriteNormal;
        }
    }

    public static class CanStatus {
        private int canIndex;
        private boolean isConnected;

        public int getCanIndex() {
            return canIndex;
        }

        public void setCanIndex(int canIndex) {
            this.canIndex = canIndex;
        }

        public boolean isConnected() {
            return isConnected;
        }

        public void setConnected(boolean connected) {
            isConnected = connected;
        }
    }
}


